package cn.tedu.oa_system.pojo;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.io.Serializable;
import java.util.Objects;

/**
 * @Author MW
 * @Description 角色权利列表实体类
 * @CreateDate 2023/3/5
 */
@Data
@TableName(value = "role_power_list")
public class RolePowerList implements Serializable {

    static final long serialVersionUID = 1L;

    @TableId
    private Long pkId;

    private Integer isShow;

    private Long menuId;

    private Long roleId;

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        RolePowerList that = (RolePowerList) o;
        return Objects.equals(pkId, that.pkId) && Objects.equals(isShow, that.isShow) && Objects.equals(menuId, that.menuId) && Objects.equals(roleId, that.roleId);
    }

    @Override
    public int hashCode() {
        return Objects.hash(pkId, isShow, menuId, roleId);
    }

    @Override
    public String toString() {
        return "RolePowerList{" +
                "pkId=" + pkId +
                ", isShow=" + isShow +
                ", menuId=" + menuId +
                ", roleId=" + roleId +
                '}';
    }
}
